<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:layout="http://www.ultraq.net.nz/web/thymeleaf/layout"
      xmlns:th="http://www.thymeleaf.org"
      layout:decorator="mgt/layout">
<head>
	<title>资源管理</title>
	<style type="text/css">
		.button{
			color: red;
			background-color:red ;
		}
	</style>
	<script>
		//<![CDATA[
		var editor;
		KindEditor.ready(function(K) {
			editor = K.create('textarea[name="content"]', {
				allowFileManager : true,
				afterBlur: function(){this.sync();}
			});
		});

		var checkSub = function(){
			var nameValue=$("#name").val();
			var passwordValue=$("#password").val();
			if(nameValue!=null&&nameValue!=""&&passwordValue!=null&&passwordValue!=""){
				$("#button").removeAttr("disabled").addClass("button");
			}else {
				$("#button").attr("disabled", "disabled").removeClass("button");
			}
		};

	$(function(){
		$("#name,#password").on("input",checkSub);
	})
		//]]>
	</script>
</head>
<body>
<div id="content" layout:fragment="content">
	<!--<div class="box-content">
		<textarea name="content" style="width:800px;height:400px;visibility:hidden;">KindEditor</textarea>
	</div>


	<form>
		<table>
			<tr>
				<td>姓名</td>
				<td><input type="text" name="name" id="name" /></td>
			</tr>
			<tr>
				<td>密码</td>
				<td><input type="password" name="password" id="password"/> </td>
			</tr>
			<tr>
				<td><button style="color: #d3d3d3" disabled="disabled" id="button">提交</button></td>
			</tr>

		</table>
	</form>-->
</div>
</body>
</html>
